﻿@model RH.Web.ViewModels.UtilityModels.ListConfig
@using RH.Web.Utility;
@using RH.Web.ViewModels.UtilityModels;
@{
    String _PageTitle = "Project List";
    ViewBag.Title = Html.GetPageTitle(_PageTitle);
    PagerConfig _PagerConfig = Model.Pager;
    _PagerConfig.TotalRecordMessage = "Total {0} Products Found";
    _PagerConfig.UrlFormat = "/private/product/list/{0}";
    ViewBag.DataSource = Model.DataSource;
    if (UserInfo.IsCompanyUser) {
        ViewData[AppConstants.ViewDataKeys.SELECTED_MENU] = CompanyMenu.Projects;
    }
    Model.AdhokModel = true; //Show Edit Link
}
<div class="rh-page-heading">
    <h1>@_PageTitle</h1>
    <div>
        Add/Edit and Manage Projects of your company.
    </div>
</div>
<div class="rh-page-content">
    @*<div class="pull-left"></div>
    <div class="pull-right"><a class="btn btn-success" href="@Url.PrivateUrl("Edit", "Product")"><i class="glyphicon glyphicon-plus"></i> Add New Project</a></div> 
    <div class="clearfix"></div>*@
    <div class="panel panel-success">
        <div class="panel-heading">
            <div class="pull-left"><h4>List of Projects</h4></div>
            <div class="pull-right"><a class="btn btn-success" href="@Url.PrivateUrl("Edit", "Product")"><i class="glyphicon glyphicon-plus"></i> Add New Project</a></div>
            <div class="clearfix"></div>
        </div>
        <div class="panel-body">
            @Html.Partial("_ProductList")
        </div>
    </div>
    
    @if (_PagerConfig != null)
    {    
        @Html.Partial("_Pager", _PagerConfig)
    }
</div>

@section PageHeadSection{
    <style type="text/css">
        .panel-body{padding-top:0px; padding-bottom:0px;}
    </style>
}
